<?php
/**
 * 提现模型
 */
namespace Admin\Model;
use Think\Model;
class WithdrawalApplyModel extends Model {
	//查询记录
	public function withdrawal_list($where=array(),$limit = ''){
		if(!empty($where) && is_array($where)){
			$this->where($where);
		}
		if(!empty($limit)){
			$result = $this->limit($limit)->order('id desc')->select();
		}else{
			$result = $this->order('id desc')->select();
		}
		return $result;
	}
	
	//查询提现记录数量
	public function getWithdrawalNum($where = array()){
		if (!empty($where) && is_array($where)) {
			$this->where($where);
		}
		return $this->count();
	}
}